import 'package:webview_flutter/webview_flutter.dart';


typedef Router = Function(String path);

class FlutterWebViewController extends WebViewController {

  Future<void> addRouterHandler(Router router) {
    return super.addJavaScriptChannel("Router", onMessageReceived: (JavaScriptMessage message) {
      router(message.message);
    });
  }

}